package com.hongtech.framework.config;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.annotation.Configuration;

@Configuration
public class OssConfig {

    // 类型 0-本地，1：七牛
    @Value("${oss.type}")
    private Integer type;

    // 本地文件服务器
    @Value("${oss.localDomain}")
    private String localDomain;

    // 本地前綴域名
    @Value("${oss.localPrefix}")
    private String localPrefix;

    // 本地上传文件位置
    @Value("${oss.localUploadDir}")
    private String localUploadDir;

    // 七牛绑定的域名
    @Value("${oss.qiniuDomain}")
    private String qiniuDomain;

    // 七牛路径前缀
    @Value("${oss.qiniuPrefix}")
    private String qiniuPrefix;

    // 七牛ACCESS_KEY
    @Value("${oss.qiniuAccessKey}")
    private String qiniuAccessKey;

    // 七牛SECRET_KEY
    @Value("${oss.qiniuSecretKey}")
    private String qiniuSecretKey;

    // 七牛存储空间名
    @Value("${oss.qiniuBucketName}")
    private String qiniuBucketName;

    public Integer getType() {
        return type;
    }

    public void setType(Integer type) {
        this.type = type;
    }

    public String getLocalDomain() {
        return localDomain;
    }

    public void setLocalDomain(String localDomain) {
        this.localDomain = localDomain;
    }

    public String getLocalPrefix() {
        return localPrefix;
    }

    public void setLocalPrefix(String localPrefix) {
        this.localPrefix = localPrefix;
    }

    public String getLocalUploadDir() {
        return localUploadDir;
    }

    public String getQiniuDomain() {
        return qiniuDomain;
    }

    public String getQiniuPrefix() {
        return qiniuPrefix;
    }

    public String getQiniuAccessKey() {
        return qiniuAccessKey;
    }

    public void setQiniuAccessKey(String qiniuAccessKey) {
        this.qiniuAccessKey = qiniuAccessKey;
    }

    public String getQiniuSecretKey() {
        return qiniuSecretKey;
    }

    public String getQiniuBucketName() {
        return qiniuBucketName;
    }

}
